<?php
/**
 * 货单路由
 */
Route::group(['prefix' => 'order','namespace'=>'Order'],function() {
    Route::group(['prefix' => 'bale'],function() {
        //货单分类
        Route::post('/cate', 'BaleController@getCateList');
        //货单列表
        Route::post('/list', 'BaleController@getBaleList');
        //货单详情
        Route::post('/detail', 'BaleController@categoryOrdersDetail');
        //抢单详情
        Route::post('/grapdetail', 'BaleController@grapDetail');
        //抢单详情
        Route::post('/grapdetail2', 'BaleController@grapDetail2');
        //确认抢单
        Route::post('/confirm-graporder', 'BaleController@confirmGrapOrder');
        //支付保证金-检验
        Route::post('/payorder', ['uses' => 'BaleController@payorder', 'as' => 'pay.payorder' ]);
        //支付保证金
        Route::post('/pay-grap', ['uses' => 'BaleController@payGrap', 'as' => 'pay.alipay.grap' ]);
    });

    Route::group(['prefix' => 'my'],function() {
        //我的订单（抢单和生产的订单，前期不需要分页）
        Route::get('/get', 'MyOrderController@getOrderList');
        //我发布的订单
        Route::get('/push', 'MyOrderController@pushOrderList');
        //我发布的订单 - 发布订单
        Route::post('/pushing', 'MyOrderController@pushOrder');
        //改变订单状态
        Route::post('/update', 'MyOrderController@updateOrder');
        //评价订单
        Route::post('/comment', 'MyOrderController@commentOrder');
        //订单详情
        Route::get('/detail', 'MyOrderController@orderDetail');
        //跟单报告
        Route::get('/report', 'MyOrderController@orderReport');
    });
});

